1. Field of the Invention
The present disclosure relates generally to environmental gas sensors, and more particularly to sensor drift correction for such sensors.
2. Description of Related Art
Environmental gas sensors generally detect the presence of a constituent gas in a gas mixture. For instance, one common application of environmental gas sensing is the measurement of carbon dioxide (CO2) concentration in an ambient environment such as an office, meeting room, greenhouse, or exhaust stream.
Non-Dispersive Infrared (NDIR) gas sensors represent a large segment of the existing CO2 sensor market. FIG. 1 contains a block diagram for a typical NDIR sensor 100. A gas sensor 110 contains a measurement chamber, into which an ambient gas mixture is either forced or diffused. Radiation of a wavelength absorbed by CO2 is introduced into the chamber by a radiation source, and a radiation sensor measures the amount of unabsorbed radiation. Generally gas sensor 110 also contains an analog amplifier, and outputs an amplified electrical signal representative of the radiation sensor reading. An analog to digital (A/D) converter 120 periodically digitizes the analog signal and supplies the digitized readings to a processor 130. Processor 130 uses programming instructions and calibration values stored in memory 140 to convert the readings to desired outputs. The outputs may be displayed or encoded CO2 readings in parts per million (PPM) units, voltage- or current-coded control signals to control air handling equipment, etc.
In one typical application, a CO2 sensor is deployed in a building to assist the air handling system in controlling the amount of fresh air supplied to various areas of the building. When a measured room or area is unoccupied, the CO2 readings decrease toward a background level, even with minimal fresh air introduction. During the times that the building is occupied, however, CO2 readings can rapidly increase from the background level. For an office building that is occupied during the day but not at night, FIG. 2 shows an exemplary plot 200 of measured CO2 concentration versus time. The line marked “SETPOINT” is the desired maximum CO2 concentration. During the time of day that the building is occupied, the CO2 concentration rises to SETPOINT and is then controlled around that point. As the building becomes vacant or near-vacant at the end of the workday, the CO2 concentration decreases toward the background level, until the next time period in which the building becomes occupied.
Almost all NDIR sensors exhibit sensor drift over time, due to contaminants on and/or corrosion of the measurement chamber, aging of the light source, sensors, filters, and amplifiers, etc. Although recalibration using known sample gas mixtures is possible, it is often inconvenient to recalibrate sensors often enough to avoid significant drifts.
Without recalibration, drifting sensor readings cause a controlled system to control to a different maximum concentration, and uncontrolled systems to report in error. FIG. 2 contains a plot 200 of measured concentration versus time. Plot 200 shows sensor drift producing measured values that, over time, decrease below the actual CO2 readings. FIG. 3 contains a similar time history of measured values that, over time, increase above the actual CO2 readings. In the FIG. 2 scenario, the result is that the control setpoint gradually allows for a greater CO2 concentration than that desired during the building-occupied portions of the day. In the FIG. 3 scenario, the result is that the control setpoint gradually allows for a lower CO2 concentration that that desired during the building-occupied portions of the day.
For a CO2 sensor used in an application where the measured ambient frequently falls to a background CO2 concentration, algorithms have been developed to compensate for sensor drift. U.S. Pat. No. 6,526,801 contains an example of a prior art sensor drift correction algorithm. The algorithm attempts to discern “quiescent periods” during which the CO2 concentration remains stable. When such a quiescent period is found, an estimated CO2 concentration and time observed for that period is added to a list of other quiescent periods that have been observed. When a quiescent period seems to grossly disagree with other observed readings, it may be rejected. After many such readings have been logged, a curve fit that estimates sensor drift is applied to the readings. FIGS. 2 and 3 show example curve fits, assuming that “quiescent periods” have been found that correspond to baseline CO2 levels.
Once a curve fit has been estimated, the difference between a set baseline CO2 level and the value of the curve as projected to the current time is used to adjust the sensor readings going forward in time. This allows gradual, predictable sensor drifts to be compensated in order to add a measure of long-term stability to the sensor output.